<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:t="http://myfaces.apache.org/tomahawk"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:ui="http://java.sun.com/jsf/facelets">  
<body>
<ui:composition template="../template/template.xhtml">
<ui:define name="central">
	<div align="center">
	    <h:panelGroup>
	        <f:facet name="header">
	        	<h:outputText value="#{msg.CadastrarAluno}" />
	        </f:facet>
	        <h:form id="formCadAluno">
	        <h:panelGrid columns="3">
				<h:outputText value="#{msg.Nome}" />
				<h:inputText value="#{Aluno.aluno.nome}" id="nomeAluno" required="true" requiredMessage="#{msg.CampoObrigatorio}"/>
				<t:message for="nomeAluno"/>
				
				<h:outputText value="#{msg.Sobrenome}" />
				<h:inputText value="#{Aluno.aluno.sobrenome}" id="sobrenomeAluno" required="true" requiredMessage="#{msg.CampoObrigatorio}"/>
				<t:message for="sobrenomeAluno"/>
				
				<h:outputText value="#{msg.NomeMae}" />
				<h:inputText value="#{Aluno.aluno.nomeMae}" id= "nomeMaeAluno" required="true" requiredMessage="#{msg.CampoObrigatorio}"/>
				<t:message for="nomeMaeAluno"/>
				
				<h:outputText value="#{msg.DataNascimento}" />
				<rich:calendar value="#{Aluno.dataAniversarioAluno}" id="dtNascAluno" showFooter="false"  required="true" requiredMessage="#{msg.CampoObrigatorio}"/>
				<t:message for="dtNascAluno"/>
				
				<h:outputText value="#{msg.Turma}" />
				<h:selectOneMenu value="#{Aluno.aluno.turma}"  id="turmaAluno" required="true" requiredMessage="#{msg.CampoObrigatorio}">
					<f:selectItem itemLabel="A" itemValue="A" />
					<f:selectItem itemLabel="B" itemValue="B" />
					<f:selectItem itemLabel="C" itemValue="C" />
					<f:selectItem itemLabel="D" itemValue="D" />
					<f:selectItem itemLabel="E" itemValue="E" />
				</h:selectOneMenu>
				<rich:message for="turmaAluno"/>
				
				<h:outputText value="#{msg.Email}" />
				<h:inputText value="#{Aluno.aluno.login}" id="emailAluno" required="true" requiredMessage="#{msg.CampoObrigatorio}">
					<f:validator validatorId="validadorEmail"/>
				</h:inputText>
				<rich:message for="emailAluno"/>
				
				<h:outputText value="#{msg.Senha}" />
				<h:inputSecret value="#{Aluno.aluno.senha}" id="senhaAluno" required="true" requiredMessage="#{msg.CampoObrigatorio}"/>
				<rich:message for="senhaAluno"/>
				
				<h:commandButton action="#{Aluno.cadastrarAluno}" value="#{msg.Cadastrar}"/>
		 	</h:panelGrid>
		 	</h:form>
		 	<h:outputText value="#{msg.TodosCamposObrigatorios}" />
		</h:panelGroup>
	</div>
 </ui:define>
</ui:composition>
</body> 
</html>
